Current Location: Blog >
Singapore CN2
1.
overview and objectives
1) goal: build a high-availability load balancing in alibaba cloud singapore cn2 environment to ensure 99.99% business availability.2) applicable scenarios: multinational e-commerce, api gateways, game login servers and other delay-sensitive services.
3) network characteristics: cn2 is directly connected back to china, with an average one-way delay of about 40ms (singapore -> eastern china).
4) core components: ecs (backend), slb/haproxy (load balancing), alibaba cloud cdn, anti-ddos.
5) sla indicators: failover <10 seconds, health check interval 5s, timeout 2s.
2.
architecture design
1) dual availability zone deployment: place at least one set of ecs in singapore-a and singapore-b.2) cross-machine room load: use alibaba cloud slb (off-site redundancy) + private network connection for heartbeat.
3) session retention: select the source ip or cookie stickiness according to the business to avoid session loss.
4) health check: http get /health, interval 5s, failure threshold 3 times and recovery threshold 2 times.
5) monitoring alarms: combined with cloud monitoring, set cpu>70%, delay>200ms alarms and automatically expand the capacity.
3.
instance and network configuration examples
1) sample backend server specifications: ecs.c6.large, 2 vcpu, 4gb memory, public network bandwidth 100mbps.2) operating system: ubuntu 20.04 lts, kernel optimization tcp_tw_reuse=1, net.ipv4.tcp_fin_timeout=30.
3) connection number optimization: ulimit -n 200000, nginx worker_connections 4096.
4) anti-ddos: turn on anti-ddos pro basic, threshold 1gbps, burst traffic protection for 5 minutes.
5) example response indicators: a single ecs handles static requests at 8000 rps, with an average delay of 18ms.
| node | ip | role | weight |
|---|---|---|---|
| ecs-1 | 10.0.1.11 | backendweb | 120 |
| ecs-2 | 10.0.2.12 | backendweb | 120 |
| haproxy | 10.0.0.5 | front-end load | - |
4.
haproxy configuration and examples
1) front-end monitoring: bind 0.0.0.0:80 and use option httpchk to set the health check path.2) back-end strategy: use roundrobin or weight-based load distribution.
3) timeout settings: timeout connect 5s, timeout client 30s, timeout server 30s.
4) session persistence: stick on src or cookie, depending on the business.
5) example snippet (brief display):
frontend http_front bind *:80 default_backend web_back backend web_back mode http balance roundrobin option httpchk get /health server web1 10.0.1.11:80 weight 120 check server web2 10.0.2.12:80 weight 120 check
5.
real cases and fault recovery
1) case company: a cross-border e-commerce company deploys international settlement services in singapore cn2.2) configuration: 2 az, 3 ecs.c6.large each, front-end slb + two haproxy for active-active.
3) traffic peak: single-day peak value 350k rps, peak bandwidth 420mbps, 86% request mitigation by cdn cache.
4) fault drill: shut down the singapore-a host group, the failover time is 6 seconds on average, and no business interruption is reported.
5) optimization effect: using the cn2 backend link, the average delay is 15ms lower than that of the ordinary public network, and the user experience is significantly improved.
6.
operation, maintenance and security suggestions
1) cdn offloading: static resources are cached by alibaba cloud cdn, reducing the pressure and cost of returning to the source.2) ddos protection: enable anti-ddos pro and combine it with the whitelist rate limiting strategy.
3) automatic expansion: combined with alibaba cloud elastic scaling, automatically add/delete ecs backends based on tps.
4) logs and auditing: centrally collect access logs, set abnormal traffic threshold alarms and trigger script flow limiting.
5) regular drills: conduct disaster recovery drills every quarter to verify the health check and automatic switching process.

- Latest articles
- SEO Optimization Perspective: Vietnam Vps Cn2’s Positive Impact On Local Access Rankings
- Five Technical Indicators That Cannot Be Ignored When Choosing Low-price Taiwan Vps Cloud Space
- Which Vps In Singapore Is Easy For Beginners To Use And Some Buying Suggestions?
- Optimization Means Korean Dial-up Vps20M Flow Control And QoS Configuration To Improve Access Experience
- Analysis Of Vps Dynamic Malaysia’s Impact On Anti-blocking And Privacy Protection From A Network Security Perspective
- How To Negotiate For A Better Cn2 Price In Singapore, Including Contract Terms And Service Guarantee Tips
- Summary Of Malaysian Cn2 Server Tuning Experience In High-concurrency E-commerce Scenarios
- How To Use Korean Native IP With CDN And Load Balancing In Enterprise-level Solutions To Improve Experience
- Communication And Privacy Rules You Need To Know Before Joining Amazon Japan Sellers’ WeChat Group
- Key Points Of Deployment And Optimization Of Korean Large-bandwidth Server Rental In The Live Broadcast Industry
- Popular tags
Network Connection Speed
Av1
Stress Test
America's Fastest Vps
Market Prospects
Community Discounts
Third-party Interface Testing
Scanning Explosion Phenomenon
Cloud Server Recommendation
Server Technology
User Impact
Station Group Server
Online Release
Browser Optimization
Choose A VPS Host
Mobile Brand
Answers
Hong Kong High-defense Server
Business Efficiency
American Cloud Torch Server
Discount Code
Synchronized With Us Time
Startups
Translation Service
Server Usage Scenarios
Disaster Recovery
Access Speed
Affordable
Configuration Guide
Ddos Defense
Related Articles
-
Advantages And Choice Guide For Cn2 Broadband Hong Kong Singapore
explore the advantages of cn2 broadband in hong kong and singapore and learn how to choose the right broadband service for you. -
How To Choose CN2 Broadband For Multi-site Architectures To Achieve Stable Connectivity In Hong Kong And Singapore
This article provides guidance on how to select CN2 broadband in Hong Kong and Singapore for a multi-site architecture, from aspects such as network paths, bandwidth specifications, BGP multipath, server/VPS selection, domain name and CDN integration, high-level DDoS protection solutions, and monitoring/testing. It also offers purchasing recommendations to ensure stable connectivity. -
How To Choose Singapore Cn2 Vps Service To Improve Website Performance
this article will introduce how to choose singapore cn2 vps service to improve website performance, including selection criteria, service provider recommendations and usage tips.